{% extends 'bootstrap-modal-layout.html.twig' %}

{% set modal_class = 'modal-ln' %}

{% block title %}{{'my.teaching.question_bank.question_category.create'|trans}}{% endblock %}

{% do script(['libs/jquery-validation.js', 'app/js/question-category/create/index.js']) %}

{% block body %}
  <div id="post-widget">
    <form class="form-horizontal" id="category-form" action="{{ path('question_bank_manage_question_category_batch_create',{id: bankId, parentId:parentId}) }}" method="post">
      <div class="form-group">
        <div class="question-bank__model-tips">{{ 'my.teaching.question_bank.question_category.create_hint'|trans }}</div>
        <label class="col-md-2 question-bank__model-names" for="category-names">{{'my.teaching.question_bank.question_category.name_label'|trans}}</label>
        <div class="col-md-8 controls">
          <textarea id="category-names" name="categoryNames" class="form-control" rows="10" style="width: 460px"></textarea>
          <div class="help-block"></div>
        </div>
      </div>
      <input type="hidden" name="parentId" value="{{ parentId|default(0) }}">
      <input type="hidden" name="_csrf_token" value="{{ csrf_token('site') }}">
    </form>
  </div>
{% endblock %}

{% block footer %}
  <button type="button" class="btn btn-link" data-dismiss="modal" tabindex="6">{{'form.btn.cancel'|trans}}</button>
  <button id="category-create-btn" data-submiting-text="{{'form.btn.submit.submiting'|trans}}" type="submit" class="btn btn-primary" data-toggle="form-submit" data-target="#category-form" tabindex="4">{{'form.btn.save'|trans}}</button>
{% endblock %}


